package com.ruoyi.web.controller.smartHighway;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.smartHighway.service.IAppService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;
import java.util.Map;

/**
 * AppController
 * 
 * @author ljj
 * @date 2024-08-06
 */
@Api("app接口")
@RestController
@RequestMapping("/smartHighway/sync")
public class AppSyncController extends BaseController{

    @Autowired
    private IAppService appService;


    @ApiOperation("同步收费站运营数据")
    @GetMapping(value = "sync_tollOperation")
    public AjaxResult sync_tollOperation() {
        return success(appService.sync_tollOperation());
    }

    @ApiOperation("同步设备列表数据")
    @GetMapping(value = "sync_deviceList")
    public AjaxResult sync_deviceList() {
        return success(appService.sync_deviceList());
    }

    @ApiOperation("同步设备种类和数量")
    @GetMapping(value = "sync_deviceNum")
    public AjaxResult sync_deviceNum() {
        return success(appService.sync_deviceNum());
    }

    @ApiOperation("同步设施列表数据")
    @GetMapping(value = "sync_facilityList")
    public AjaxResult sync_facilityList() {
        return success(appService.sync_facilityList());
    }

    @ApiOperation("同步设施种类和数量")
    @GetMapping(value = "sync_facilityNum")
    public AjaxResult sync_facilityNum() {
        return success(appService.sync_facilityNum());
    }

    @ApiOperation("同步公路技术状况桥梁等级评分列表")
    @GetMapping(value = "sync_bridgeGradeList")
    public AjaxResult sync_bridgeGradeList() {
        return success(appService.sync_bridgeGradeList());
    }

    @ApiOperation("同步桥梁详情列表")
    @GetMapping(value = "sync_bridgeInfoList")
    public AjaxResult sync_bridgeInfoList() {
        return success(appService.sync_bridgeInfoList());
    }

    @ApiOperation("同步公路技术状况路面等级评分列表")
    @GetMapping(value = "sync_roadGradeList")
    public AjaxResult sync_roadGradeList() {
        return success(appService.sync_roadGradeList());
    }

//    待补充 事件相关
    @ApiOperation("同步事件列表")
    @PostMapping(value = "sync_eventInfo")
    public AjaxResult sync_eventInfo(@RequestBody Map<String,Object> queryMap) {
        return success(appService.sync_eventInfo(queryMap));
    }

//    6.1、养护工程 同步
    @ApiOperation("同步养护工程列表")
    @GetMapping(value = "sync_showInfoList")
    public AjaxResult sync_showInfoList() {
        return success(appService.sync_showInfoList());
    }

    @ApiOperation("同步养护工程单个")
    @GetMapping(value = "sync_showInfo")
    public AjaxResult sync_showInfo() {
        return success(appService.sync_showInfo());
    }

    @ApiOperation("同步结构物基础信息列表")
    @GetMapping(value = "sync_showStructureList")
    public AjaxResult sync_showStructureList() {
        return success(appService.sync_showStructureList());
    }


}
